<div class="SipeiMain_r fr">
    <h2 class="clearfix fonts_18 height45 fontc_444"><?php echo $this->title; ?></h2>
    <div class="clearfix back_bgf border_3 border_c pr30 pl30 pt20 pb20 height32 fontc_666">
        <form action="<?php echo $this->createUrl('/report_rule/default/outlist')?>" method="GET"  id='searchForm'>
            <ul class="clearfix">
                <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:63px;">考试项目：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                            <select class="fl fontc_666" name="exam_id">
                                <option value="0">请选择</option>
                                <?php foreach ($date['ztask'] as $v): ?>
                                    <option value="<?php echo $v['exam_id']; ?>" <?php
                                    if ($info['exam_id'] == $v['exam_id']) {
                                    	echo "selected=selected";
                                    }
                                    ?> ><?php echo $v['exam_term_name']; ?></option>
                                        <?php endforeach; ?>
                            </select> 
                        </span> 
                    </span>
                </li>
                <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:85px;">所属学校：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                            <select class="fl fontc_666" name="school_id">
                                <option value="0">请选择</option>
                                <?php foreach ($date['school'] as $v): ?>
                                    <option value="<?php echo $v['school_id']; ?>" <?php
                                    if ($info['school_id'] == $v['school_id']) {
                                    	echo "selected=selected";
                                    }
                                    ?> ><?php echo $v['school_name']; ?></option>
                                        <?php endforeach; ?>
                            </select> 
                        </span> 
                    </span>
                </li>
                <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:63px;">类别：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
							  <select class="fl fontc_666" name="disciplin_id">
                                <option value="0">请选择</option>
								<option value="1" <?php
                                if ($info['disciplin_id'] == 1) {
                                	echo "selected=selected";
                                }
                                ?> >理科</option>
                                <option value="2" <?php
                                if ($info['disciplin_id'] == 2) {
                                	echo "selected=selected";
                                }
                                ?> >文科</option>
                                <option value="3" <?php
                                if ($info['disciplin_id'] == 3) {
                                	echo "selected=selected";
                                }
                                ?> >艺体</option>
                            </select> 
                        </span> 
                    </span>
                </li>
				
         <!--      <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:85px;">所属科目：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                           <select class="fl fontc_666" name="subject_id">
                                <option value="0">请选择</option>
                                <?php foreach ($date['subject'] as $k => $v): ?>
                                    <option value="<?php echo $k; ?>" <?php
                                    if ($info['subject_id'] == $k) {
                                    	echo "selected=selected";
                                    }
                                    ?> ><?php echo $v; ?></option>
                                        <?php endforeach; ?>
                            </select> 
                        </span> 
                    </span>
                </li>
				-->
			<li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:85px;">所属科别：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                           <select class="fl fontc_666" name="disciplin_code">
                                <option value="0">请选择</option>
								
								<?php if(!empty($date['disciplin'])) : ?>
                                <?php foreach ($date['disciplin'] as $k => $v): ?>
                                    <option value="<?php echo $v['disciplin_id']; ?>" <?php
                                    if ($info['disciplin_code'] == $v['disciplin_id']) {
                                    	echo "selected=selected";
                                    }
                                    ?> ><?php echo $v['disciplin_nick']; ?></option>
                                        <?php endforeach; ?>
										<?php endif; ?>
                            </select> 
                        </span> 
                    </span>
                </li>	
				
                <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:63px;">所属班级：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                            <select class="fl fontc_666" name="class_name">
                                <option value="0">请选择</option>
                                <?php foreach ($date['class'] as $v): ?>
                                    <option value="<?php echo $v['class_name']; ?>" <?php
                                    if ($info['class_name'] == $v['class_name']) {
                                    	echo "selected=selected";
                                    }
                                    ?> ><?php echo $v['class_name']; ?></option>
                                        <?php endforeach; ?>
                            </select> 
                        </span> 
                    </span>
                </li>
                <li class="fl pt10 pr30 pb10">
                    <span class="fl pr3 text_right" style="width:85px;">导出数据范围：</span>
                    <span class="fl standard_select pt5 pr7 pb5 pl3 border_c border_3"> 
                        <span class="fl select_shelter"> 
                            <select class="fl fontc_666" name="nojoinstatus">
                                <option value="">所有学生数据</option>
                                <option value="T" <?php
                                if ($info['nojoinstatus'] == 'T') {
                                	echo "selected=selected";
                                }
                                ?> >参加统计学生数据</option>
                                <option value="F" <?php
                                if ($info['nojoinstatus'] == 'F') {
                                	echo "selected=selected";
                                }
                                ?>>不参加统计学生数据</option>
                                <option value="Y"  <?php
                                if ($info['nojoinstatus'] == 'Y') {
                                	echo "selected=selected";
                                }
                                ?>>参加考试学生数据</option>
                                <option value="N"  <?php
                                if ($info['nojoinstatus'] == 'N') {
                                	echo "selected=selected";
                                }
                                ?>>未参加考试学生数据</option>
                            </select> 
                        </span> 
                    </span>
                </li>
            </ul>
            <div class="clearfix pt10 pb10 text_align">
                <input type="submit" value="查询" class="b_a_n border_3 back_bgfb w80 height32 fontc_FFF fonts_12 mr10 cursor" />
                <input type="submit" value="导出" name="import" class="b_a_n border_3 back_bgfb w80 height32 fontc_FFF fonts_12 cursor" />
            </div>
        </form> 
    </div>
	<?php if (!empty($info['detaildata'])):?>
    <div class="clearfix back_bgf border_c mt15 pt20 pb20">
        <form>
            <table class="height40">
                <thead class="back_bgf5 fontc_666">
                    <tr>
                    	
                    	<?php $count = count($info['detaildata']);?>
                    	<?php foreach ($info['detaildata'] as $k=>$v): ?>
                        <th width="800" align="center" class="m_hr_t m_hr_b"><?php if (!empty($v['name'])){echo $v['name'];}else{ echo '';}?></th>
                         <?php endforeach;?>
                        
                    </tr>
                </thead>
                <tbody class="fontc_444">
                    <?php if (!empty($data)): ?>
                        <?php foreach ($data as $value): ?>
                         <?php if (!empty($info['detaildata'])): ?>
                         	<tr>
                         	<?php foreach ($info['detaildata'] as $k=>$v): ?>
                            	<td align="center" class="m_hr_b">
                            	<?php 
                            	if (!empty($v['value'])):
                            		echo $v['value'];
                            	else: 
                            		if($v['row'] == 'exam_id'):
                            			echo isset($examInfo[$value[$v['row']]])?$examInfo[$value[$v['row']]]['exam_term_name']:'';
                            		else:
                            			echo isset($value[$v['row']])?$value[$v['row']]:'';
                            		endif;
                            	endif; ?></td>
                          	<?php endforeach;?>
                            </tr>
                        <?php endif;?>
                     <?php endforeach; ?>
                    <?php else: ?>
                        <tr>
                                <?php if(isset($count)): ?>
                                 <td colspan="<?php echo $count?>" align="center">暂无数据</td>
                                <?php else: ?>
                                 <td align="center" class="pl20">暂无数据</td>
                                <?php endif; ?>
                        </tr>
                    <?php endif; ?>
                </tbody>
            </table>
        </form>
        <?php $this->renderPartial('//partial/partial_pager', array('pages' => $pages, "url" => $pageUrl)); ?>
    </div>
	<?php else:?>
	 <div class="clearfix back_bgf border_c mt15 pt20 pb20">
        <form>
            <table class="height40">
    
                <tbody class="fontc_444">
                    
                        <tr>
                               
                                 <td width="800" align="center" class="pl20">暂无DBF参数设置数据</td>
                     
                        </tr>
      
                </tbody>
            </table>
        </form>   
    </div>
	<?php endif;?>
</div>
